package com.qf.mrboot1.controller;

import com.qf.mrboot1.entity.Order;
import com.qf.mrboot1.result.ResponseData;
import com.qf.mrboot1.service.OrderService;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * (Order)表控制层
 *
 * @author makejava
 * @since 2021-06-02 09:41:11
 */
@RestController
@RequestMapping("order")
public class OrderController {
    /**
     * 服务对象
     */
    @Resource
    private OrderService orderService;

    @ApiOperation(value = "createOrder",notes = "添加预约记录")
    @PostMapping("createOrder")
    public ResponseData createOrder(@RequestBody Order order){

        return orderService.insert(order);
    }

}
